// Settings For MDUI
var $ = mdui.$;

var inst = new mdui.Drawer('#drawer');

// method


document.getElementById('toggle').addEventListener('click', function () {
    inst.toggle();
});


// event
var drawer = document.getElementById('drawer');
drawer.addEventListener('open.mdui.drawer', function () {
    console.log('open');
});
drawer.addEventListener('opened.mdui.drawer', function () {
    console.log('opened');
});
drawer.addEventListener('close.mdui.drawer', function () {
    console.log('close');
});
drawer.addEventListener('closed.mdui.drawer', function () {
    console.log('closed');
});

function show(){
	mdui.snackbar({
	  message: 'Hi,MDUI!',
	  buttonText: 'Close',
	  onClick: function(){
	    mdui.alert('欢迎访问并 <code>Star Gitee</code> 仓库 <code><a href="https://gitee.com/heyos/mdui">HeyOS/MDUI</a></code>！');
	  },
	  onButtonClick: function(){
	    mdui.alert('欢迎访问并 <code> Star Gitee</code> 仓库 <code><a href="https://gitee.com/heyos/mdui">HeyOS/MDUI</a></code>！');
	  },
	  onClose: function(){
	    
	  }
	});

}
function gitee(){
	mdui.alert('欢迎访问并 <code> Star Gitee</code> 仓库 <code><a href="https://gitee.com/heyos/mdui">HeyOS/MDUI</a></code>！');
}